<?php
namespace app\index\controller;
use think\Db;
use think\Controller;
class Base extends Controller
{
    public $_user = array();
    public function initialize()
    {
        $access_token = getParam('access_token', "");
        if ($access_token != "") {
            $cur_user_id = D('UserToken')->getUserIdByAccessToken($access_token);
            if ($cur_user_id > 0) {
                $this->_user = D('User')->getSelfInfo($cur_user_id);
            }
        }
    }

}
